package com.vhall.component.controller.interactive.facade;

import com.vhall.component.entity.interactive.vo.*;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;

/**
 * @author guoxin.wang
 * @date 2021/5/11
 */
@FeignClient(value = "QuestionApiFacade", path = "/v4/api/question")
public interface QuestionApiFacade {

    /**
     * 问卷-获取列表
     *
     * @param req 参数
     * @returne 返回值
     */
    @PostMapping(value = "/lists")
    QuestionPage<QuestionListRspVO> lists(@Validated QuestionListReqVO req);

    /**
     * 问卷推屏
     *
     * @param req 参数
     * @return 返回值
     */
    @PostMapping("/repush")
    Boolean repush(@Validated QuestionPushReqVo req);

    /**
     * 问卷复制
     *
     * @param req 参数
     * @return 返回值
     */
    @PostMapping("/copy")
    Boolean copy(@Validated QuestionCopyReqVo req);


    /**
     * 是否提交过问卷
     *
     * @param req 参数
     * @return 返回值
     */
    @PostMapping("/check-survey")
    Boolean checkSurvey(@Validated QuestionCheckSurveyReqVo req);


    /**
     * 问卷-发布问卷(主播)
     *
     * @param req 参数
     * @return 返回值
     */
    @PostMapping("/publish")
    Boolean publish(@Validated QuestionPublishReqVo req);


    /**
     * 解绑问卷
     *
     * @param reqVo 参数
     * @return 返回值
     */
    @PostMapping("/unbind-room")
    Boolean unbindRoom(@Validated QuestionUnbindRoomReqVo reqVo);

    /**
     * 问卷列表-观看端
     *
     * @param req 参数
     * @return 返回值
     */
    @PostMapping(value = "/watch-list")
    QuestionPage<QuestionListRspVO> watchList(@Validated QuestionListWatcherReqVO req);
}
